home *** CD-ROM | disk | FTP | other *** search
Text File | 1996-07-03 | 587 b | 31 lines | [TEXT/R*ch] |
- print "local open Const in\n";
- print "val predef_variables = [\n";
-
- open(VARS, $ARGV[0]) || die("cannot open $ARGV[0]");
- $first = 1;
- while(<VARS>) {
- if (m|/\* (".*"),(".*") \*/|) {
- print ",\n" unless $first;
- print " {qual=\"(global)\", id=$2}";
- $first = 0;
- }
- }
- close(VAR);
-
- print "\n];\n";
- print "val predef_exn = [\n";
-
- open(EXC, $ARGV[1]) || die("cannot open $ARGV[1]");
- $first = 1;
- while(<EXC>) {
- if (m|/\* (".*"),(".*"),([0-9]+) \*/|) {
- print ",\n" unless $first;
- print " ({qual=$1, id=$2}, $3)";
- $first = 0;
- }
- }
- close(EXC);
-
- print "\n];\nend;\n";
-
-